package test.db.table.mysql.type;

import test.db.table.Table;

/**
 * @author newbie
 * @since 0.1
 */
public enum PwTagTable implements Table, ColumnType {
    SID(Column.sid),
    TAG_NAME(Column.tagName),
    HIT_CNT(Column.hitCnt),
    PARSING(Column.parsing);
    
    private final Column column;
    private static final String TYPE_TAG_NAME = "VARCHAR(64)";
    private static final String TYPE_HIT_CNT = "INT(8)";
    private static final String TYPE_PARSING = "VARCHAR(255)";

    PwTagTable(Column column) {
        this.column = column;
    }
    
    private enum Column {
        sid {
            String getType() {
                return TYPE_SID;
            }
        },
        
        tagName {
            String getType() {
                return TYPE_TAG_NAME;
            }
        },
        
        hitCnt {
            String getType() {
                return TYPE_HIT_CNT;
            }
        },
        
        parsing {
            String getType() {
                return TYPE_PARSING;
            }
        };
        
        abstract String getType();
    }
    
    public String getType() {
        return column.getType();
    }
    
    public void initData() throws Exception {
    }
}